Computer-aided design (CAD) software is a computer-based graphical design tool used to aid professional and/or amateur drafters to more effectively and efficiently create two- and three-dimensional drawings and other documents with graphical content. CAD software is used in a variety of different fields, such as engineering, architecture, automotive design, graphic design, advertising, fashion design, medicine, etc. Unlike a traditional “pen and paper” drafting space, where changes to a document require erasing previous work or discarding an old document and beginning a new document, CAD software provides a graphical user interface with a virtual layout space that may be easily altered and refined as desired using a computer. Generally, a user interacts with CAD software via input devices such as a keyboard, mouse, trackball, and/or stylus. The drafting document is displayed on a graphical display device, such as a computer monitor or screen.
Most CAD software programs allow creation of a variety of objects that may be added to a layout space and used with other objects to create complex shapes and/or objects. CAD software may provide a user with stock objects such as arcs, circles, rectangles, and other known geometric shapes and/or provide tools to create such shapes. Text boxes are also available, should a user choose to insert text into a drafting document. Often, CAD software will also provide stock images to enhance a drawing. For example, an architect may wish to include exemplary landscaping in a depiction of a building and may choose to use stock images of trees, grass, and bushes. Alternatively, a user may choose to import his or her own particular images or previously-created shapes to the layout space.
The CAD software further provides a plurality of tools for manipulation of objects already in a drafting document or workspace. For example, a user may desire to relocate an object that he or she has placed in the drafting document. A “move” tool may be provided by the CAD software so that the user can move a created object within the drafting document. Alternatively, a user may desire to change the size of an object within the drafting document. Rather than requiring the user to delete and re-draw the object at a different size, a “scale” tool may be provided so that a user may re-size an object. Other types of tools that may be provided include functions such as “paint,” “rotate,” “skew,” “move vertex,” “stretch,” “copy,” and “paste.” Buttons for invoking or selecting tools are usually provided in a “tool bar” area, which may be located along a border of the screen or the workspace, or in a movable window.
Functions such as move, rotate, stretch, scale, skew, and move vertex are examples of “affine functions.” Affine functions are provided by the CAD system as tools for refining objects that have been created, placed, or imported by the user into the CAD workspace. Generally, an affine function includes a linear transformation (e.g., rotation, scaling, or skew) and/or a translation or shift (e.g., a “move”). An affine function can be represented as:x→Ax+b  Equ. 1where x is a vector representing an object being transformed, A is a matrix representing a linear transformation, and b is a vector representing a translation or shift. Generally, an affine function preserves 1) a collinearity relation between points (i.e., the points which lie on a line continue to be collinear after the transformation), and 2) ratios of distances along a line (i.e., for distinct collinear points p1,p2,p3, the ratio |p2−p1|/|p3−p2| is preserved).
To perform an affine function on an object, a user selects the object and then selects the proper tool for the desired manipulation of the object, or vice versa. A user may then perform the desired affine function by way of user inputs, such as clicking a mouse, touching a touch screen, dragging the object or a grip on the object, dropping the object or grip at a desired location, releasing the object or grip, entering coordinates via a keyboard, or any number of suitable input methods. Once the user has completed the desired affine function, the user may choose another tool to perform another function on the object or may choose another object on which to perform the same affine function or another affine function.